package at.fhj.itm11.forum.beans.stubs;

import java.util.ArrayList;
import java.util.List;

import at.fhj.itm11.forum.service.IconService;
import at.fhj.itm11.forum.service.dtos.IconDTO;

public class IconServiceStub implements IconService {
	
	public static final Long EXISTING_ID = 1L; 

	@Override
	public List<IconDTO> retrieveAllIconsOrderedByFileName() {
		List<IconDTO> icons = new ArrayList<IconDTO>();
		IconDTO icon = new IconDTO();
		icon.setId(1L);
		icon.setFileName("info.png");
		icons.add(icon);
		return icons;
	}

	@Override
	public IconDTO findIconById(Long id) {
		if (EXISTING_ID == id) {
			IconDTO icon = new IconDTO();
			icon.setId(1L);
			icon.setFileName("info.png");
			return icon;
		}
		return null;
	}
}